<!DOCTYPE html>
<html>
<head>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
    <title>Battle city</title>
    <script src="lib/code-mirror/codemirror.js"></script>
    <script src="lib/code-mirror/runmode.js"></script>
    <script src="lib/code-mirror/pascal.js"></script>
    <link  href="lib/code-mirror/codemirror.css" rel="stylesheet">
    <link  href="lib/code-mirror/night.css" rel="stylesheet">
    
    <link rel="stylesheet" type="text/css" href="/css/layout.css">
    <link rel="stylesheet" type="text/css" href="/css/screen.css">
    <link rel="stylesheet" type="text/css" href="/css/text.css">
    <link rel="stylesheet" type="text/css" href="/css/colors.css">
    <script type="text/javascript" src="/lib/jquery.js"></script>
    <script type="text/javascript" src="/lib/node/events.js"></script>
    <script type="text/javascript" src="/css/screen.js"></script>
    <script type="text/javascript" src="/src/lang/lang.js"></script>
    <script type="text/javascript" src="/src/lang/ru.js"></script>
    <script type="text/javascript" src="/src/lang/en.js"></script>
    <script type="text/javascript" src="/src/common/func.js"></script>
    <script type="text/javascript" src="/src/common/event.js"></script>
    <script type="text/javascript" src="/src/common/list.js"></script>
    <script type="text/javascript" src="/src/common/map_tiled.js"></script>
    <script type="text/javascript" src="/src/common/premade.js"></script>
    <script type="text/javascript" src="/src/common/message.js"></script>
    <script type="text/javascript" src="/src/common/user.js"></script>
    <script type="text/javascript" src="/src/battle-city/field.js"></script>
    <script type="text/javascript" src="/src/battle-city/keyboard.js"></script>
    <script type="text/javascript" src="/src/battle-city/objects/abstract.js"></script>
    <script type="text/javascript" src="/src/battle-city/objects/animation.js"></script>
    <script type="text/javascript" src="/src/battle-city/objects/bullet.js"></script>
    <script type="text/javascript" src="/src/battle-city/objects/tank.js"></script>
    <script type="text/javascript" src="/src/battle-city/objects/tankbot.js"></script>
    <script type="text/javascript" src="/src/battle-city/objects/wall.js"></script>
    <script type="text/javascript" src="/src/battle-city/objects/delimiter.js"></script>
    <script type="text/javascript" src="/src/battle-city/objects/base.js"></script>
    <script type="text/javascript" src="/src/battle-city/objects/bonus.js"></script>
    <script type="text/javascript" src="/src/battle-city/objects/trees.js"></script>
    <script type="text/javascript" src="/src/battle-city/objects/water.js"></script>
    <script type="text/javascript" src="/src/battle-city/objects/ice.js"></script>
    <script type="text/javascript" src="/src/battle-city/objects/checkpoint.js"></script>
    <script type="text/javascript" src="/src/battle-city/client/graphic-loader.js"></script>
    <script type="text/javascript" src="/src/client/bc-client.js"></script>
    <script type="text/javascript" src="/src/client/ui/widgets/common.js"></script>
    <script type="text/javascript" src="/src/client/ui/widgets/lists.js"></script>
    <script type="text/javascript" src="/src/client/ui/widgets/chat.js"></script>
    <script type="text/javascript" src="/src/client/ui/widgets/field-view.js"></script>
    <script type="text/javascript" src="/src/client/ui/widgets/game-controls.js"></script>
    <script type="text/javascript" src="/src/client/ui/widgets/public.js"></script>
    <script type="text/javascript" src="/src/client/ui/widgets/premade.js"></script>
    <script type="text/javascript" src="/src/client/ui/widgets/game.js"></script>
    <script type="text/javascript" src="/src/client/ui/widgets/create-bot.js"></script>
    <script type="text/javascript" src="/src/client/ui/widgets/exercises.js"></script>
    <script type="text/javascript" src="/src/client/ui/widgets/help.js"></script>
    <script type="text/javascript" src="/src/client/ui/widgets/console.js"></script>
    <script type="text/javascript" src="/src/client/ui/widgets/notifier.js"></script>
    <script type="text/javascript" src="/src/client/ui/manager.js"></script>
    <script type="text/javascript" src="/src/init.js"></script>

    <script type="text/javascript" src="/src/vm/compilers/symbol-table.js"></script>
    <script type="text/javascript" src="/src/vm/compilers/pascal/parser.js"></script>
    <script type="text/javascript" src="/src/vm/vm.js"></script>
</head>
<body>
<div id="mainmenu">
    <ul class="lang-select">
        <li lang="en">en</li>
        <li lang="ru">ru</li>
    </ul>
</div>
<div id="body">
    <div id="connecting" class="ui-block" style="display: block;">
        <span class="lang" key="message-connection"></span>
    </div>
    <div id="connection-fail" class="ui-block">
        <span class="lang" key="message-connection-fail"></span>
    </div>
    <div id="disconnect" class="ui-block">
        <span class="lang" key="message-connection-closed"></span>
    </div>
    <div id="nowebsocket" class="ui-block">
        <span class="lang" key="lack-of-websocket-support"></span>
    </div>
    <div id="login" class="ui-block">
        <div class="login">
            <h4>Прочитайте пожалуйста:</h4>
            <ul class="faq">
                <li>Не верьте всему что пишут в чате, потому-что любой троль может зайти под моим ником.</li>
                <li>Управление: Стрелки - ездить, пробел - стрелять.</li>
                <li>Это просто демка, а не законченный продукт. Поэтому дизайн убогий, баги жирные.</li>
                <li>Максимум может быть только 10 игр одновременно - это
                    связанно со скорость моего интернет подключения.</li>
                <li>Конструктивную критику, баги и предложения направлять на vtk666@gmail.com</li>
            </ul>
            <form id="game-login" action="#">
                <fieldset>
                    <legend class="lang" key="legend-play"></legend>
                    <div><span class="lang" key="enter-nick"></span><input type="text" name="nick"></div>
                    <div class="submit"><button type="submit" class="lang" key="submit-play"></button></div>
                </fieldset>
            </form>
            <form id="tutor-login" action="#">
                <fieldset>
                    <legend class="lang" key="legend-learn"></legend>
                    <div><span class="lang" key="enter-nick"></span><input type="text" name="nick"></div>
                    <div class="submit"><button type="submit" class="lang" key="submit-learn"></button></div>
                </fieldset>
            </form>
            <div class="like-wrapper">
                <div id="fb-root"></div>
                <script>(function(d, s, id) {
                  var js, fjs = d.getElementsByTagName(s)[0];
                  if (d.getElementById(id)) {return;}
                  js = d.createElement(s); js.id = id;
                  js.src = "//connect.facebook.net/en_US/all.js#xfbml=1";
                  fjs.parentNode.insertBefore(js, fjs);
                }(document, 'script', 'facebook-jssdk'));</script>
                <div class="fb-like" data-href="http://vtk.tom.ru/" data-send="false" data-layout="button_count" data-width="100" data-show-faces="true" data-colorscheme="dark"></div>
            </div>
        </div>
        
        <div id="credits">
            <a class="span" href="http://www.spriters-resource.com/nes/batcity/sheet/11756">Sprites by Zephiel87</a>
            <a class="span" href="http://code.google.com/p/battle-city-js/">Source code by vtk</a>
            Powered by <a href="http://nodejs.org/">node.js</a> and <a href="http://socket.io/">socket.io</a>
        </div>
    </div>
    
    <div id="public" class="ui-block">
        <h1 class="lang" key="header-public-chat"></h1>
        <div class="user-list"><h3 class="lang" key="header-players"></h3></div>
        <div class="premades">
            <div class="lang" key="join-existen-game"></div>
        </div>
        <div class="chat">
            <div class="chat-log">
                <div class="messages"></div>
            </div>
        </div>
        <form class="message-form">
            <input type="text" name="message">
            <button type="submit" class="lang" key="submit"></button>
        </form>
    </div>
    
    <div id="create" class="ui-block">
        <h1 class="lang" key="header-create-game"></h1>
        <form id="create-form">
        <h3 class="lang" key="choose-game-type"></h3>
        <ul class="game-modes">
            <li id="classic" class="current">
                <img src="/img/client/classic.png" width="208" height="208" alt="classic"/>
                <h4 class="lang" key="game-type-classic"></h4>
                <p class="lang" key="game-type-classic-desc"></p>
            </li>
            <li id="teamvsteam">
                <img src="/img/client/teamvsteam.png" width="208" height="208" alt="teamvsteam"/>
                <h4 class="lang" key="game-type-teamvsteam"></h4>
                <p class="lang" key="game-type-teamvsteam-desc"></p>
            </li>
        </ul>
        <div>
            <span class="lang" key="enter-new-game-name"></span>
            <input type="hidden" name="type" value="classic">
            <input type="text" name="name">
            <button type="submit" class="lang" key="submit-create"></button>
        </div>
        </form>
    </div>
    
    <div id="premade" class="ui-block">
        <h1 class="lang" key="header-premade-chat"></h1>
        <div class="user-list"><h3 class="lang" key="header-players"></h3></div>
        <div class="game-controls">
            <button class="start-game lang" key="start"></button>
            <button class="exit-game lang" key="exit"></button>
            <div class="level"><span class="lang" key="prompt-level"></span> <select name="level"></select></div>
        </div>
        <div class="chat">
            <div class="chat-log">
                <div class="messages"></div>
            </div>
        </div>
        <form class="message-form">
            <input type="text" name="message">
            <button type="submit" class="lang" key="submit"></button>
        </form>
    </div>
    
    <div id="exercises" class="ui-block">
        <div class="exercise-list">
            <div class="exercise">
                <h3>Задание 1 - Алгоритм</h3>
                <p>В этом упражнении вам необходимо написать программу управления танком, которая приведет его в точку назначения.</p>
                <div class="exercise-controls">
                    <div class="select" level="1">&rarr;</div>
                </div>
            </div>
            <div class="exercise">
                <h3>Задание 2 - Алгоритм</h3>
                <p>В этом упражнении вам необходимо написать программу управления танком, которая приведет его в точку назначения.</p>
                <div class="exercise-controls">
                    <div class="select" level="2">&rarr;</div>
                </div>
            </div>
        </div>
    </div>
    
    <div id="bot-editor" class="ui-block">
        <div id="editor"></div>
        <div id="console"></div>
    </div>
    
    <div id="game" class="ui-block">
        <div id="bot-stack"></div>
        <canvas id="field" width="416" height="416"></canvas>
        <div class="player0-stats"></div>
        <div class="player1-stats"></div>
        <div class="player2-stats"></div>
        <div class="player3-stats"></div>
        
        <div class="exercise-game-controls">
            <button class="execute-code lang" key="execute-code"></button>
            <button class="restart-game lang" key="restart"></button>
            <button class="exit-exercise lang" key="exit"></button>
        </div>
        
        <div class="fb-like" data-href="http://vtk.tom.ru/" data-send="false" data-layout="button_count" data-width="100" data-show-faces="true" data-colorscheme="dark"></div>
    </div>
    
    <div id="help" class="ui-block">
        <div class="content"></div>
    </div>
</div>
</body>
</html>